﻿@model EnetaMvc.ApplicationServices.Dto.FullProfileDto
@{
    Layout = "~/Views/Shared/_ProfileLayout.cshtml";
}
<div class="content-txt">
	<!--blog-head start-->
	<div class="blog-head">
		<div class="user-foto"> <a href="@Url.Content("~/profiles/details/" + Model.Id)"><img alt="@Model.UserName" src="@Html.GetProfileUrl(Model.Id)" width="32" height="32" /></a> </div>
		<h2><a href="@Url.Content("~/profiles/details/" + Model.Id)">@Model.UserName</a></h2>
		<!--profile-nav start-->
		<ul id="profilenav">
			<li> <span class="open-submenu">&nbsp;</span> <a href="#">Lisa raamat</a>
				<div>
					<ul>
						<li><a href="#">Lisa uudis</a></li>
						<li><a href="#">Lisa ajakiri</a></li>
						<li><a href="#">Lisa firma</a></li>
						<li><a href="#">Lisa blogi</a></li>
					</ul>
				</div>
			</li>
		</ul>
		<!--profile-nav end-->
	</div>
	<!--blog-head end-||-content-info-area start-->
	<div class="content-info-area">
        @Html.ValidationSummary()
        @Html.ShowSuccessMessage((string)ViewBag.SuccessMessage)

        @if (Model.Id == Session.GetUserId())
        { 
            <h3>@Resources.EnetaMvc.You</h3>
        }
        else
        { 
            <h3>@Model.UserName</h3>
        }
        
		<div class="enter-information">
            @{ Html.BeginForm("Edit", "Profiles", FormMethod.Post, new { encType = "multipart/form-data" });}
                @Html.HiddenFor(m => m.Id)
				<fieldset>
				<!--input-holder start-->
				<div class="input-holder profile">
					<!--info-row start-->
					<div class="info-row">
						<div class="title">
							<h5>@Resources.EnetaMvc.UserName</h5>
						</div>
						<div class="information-main"> <span>@Model.UserName</span> </div>
                        @Html.HiddenFor(m => m.UserName)
					</div>
					<!--info-row end-||-info-row start-->
					<div class="info-row">
						@Html.ValidationMessageFor(m => m.FirstName)
						<div class="title">
							<h5>@Resources.EnetaMvc.FirstName</h5>
						</div>
						<div class="error-note"> <span>*</span> </div>
						<div class="information-main">
                            @Html.TextBoxFor(m => m.FirstName, new Dictionary<string,object> { {"class","text-go"} })
                            @Html.CheckBoxFor(m => m.ShowFirstName, new Dictionary<string, object> { { "class", "choice" } })
                            @Html.LabelFor(m => m.ShowFirstName, Resources.EnetaMvc.Public.ToLower())
							@Html.Tooltip("name", Resources.EnetaMvc.FirstName)
                        </div>
					</div>
					<!--info-row end-||-info-row start-->
					<div class="info-row">
						@Html.ValidationMessageFor(m => m.LastName)
						<div class="title">
							<h5>@Resources.EnetaMvc.LastName</h5>
						</div>
						<div class="error-note"> <span>*</span> </div>
						<div class="information-main">
							@Html.TextBoxFor(m => m.LastName, new Dictionary<string,object> { {"class","text-go"} })
							@Html.CheckBoxFor(m => m.ShowFirstName, new Dictionary<string, object> { { "class", "choice" } })
                            @Html.LabelFor(m => m.ShowLastName, Resources.EnetaMvc.Public.ToLower())
							<a href="inc/help2.html?width=216" id="help2" name="Perenimi" class="jTip">?</a> </div>
					</div>
					<!--info-row end-||-info-row start-->
					<div class="info-row">
                        @Html.ValidationMessageFor(m => m.Email)
						<div class="title">
							<h5>@Resources.EnetaMvc.EmailAddress</h5>
						</div>
						<div class="error-note"> <span>*</span> </div>
						<div class="information-main"><!-- example value -->
							@Html.TextBoxFor(m => m.Email, new Dictionary<string,object> { {"class","text-go"} })
							@Html.CheckBoxFor(m => m.ShowEmail, new Dictionary<string, object> { { "class", "choice" } })
							@Html.LabelFor(m => m.ShowEmail, Resources.EnetaMvc.Public.ToLower())
							<a href="inc/help2.html?width=216" id="help3" name="E-posti aadress" class="jTip">?</a> </div>
					</div>
					<!--info-row end-||-info-row start-->
					<div class="info-row sina-ja">
                        @Html.ValidationMessageFor(m => m.MyRoles)
						<div class="title">
							<h5>@Resources.EnetaMvc.MyRoles</h5>
						</div>
						<div class="error-note"> <span>*</span> </div>
						<div class="information-main">
							<span class="options" id="ctl00_PlaceHolderMain_interestsList">
                                @Html.CheckBoxList("MyRolesSelection", Html.GetMyRolesWithSelection(Model.MyRoles),"choice")
							</span>
							<!--a href="inc/help2.html?width=216" id="help4" name="Help" class="jTip" tabindex="10">
						?</a-->
						</div>
					</div>
					<!--info-row end-->
				</div>
				<!--input-holder end-||-input-holder start-->
				<div class="input-holder">
					<!--info-row start-->
					<div class="info-row">
						<div class="title">
							<h5>@Resources.EnetaMvc.AboutMe</h5>
						</div>
						<div class="information-main">
                            @Html.TextAreaFor(m => m.Description, new {cols = 40, rows = 2} )
							<a href="inc/help2.html?width=216" id="help5" name="Tutvustus" class="jTip">?</a> </div>
					</div>
					<!--info-row end-||-info-row start-->
					<div class="info-row foto-inp">
						<div class="title">
							<h5> <img alt="@Model.UserName" src="@Html.GetProfileUrl(Model.Id, 32)" width="16" height="16" /> <span>@Resources.EnetaMvc.Photo</span> </h5>
						</div>
						<div class="information-main">
                            <input type="file" style="margin: 0px; padding: 0px; opacity: 0; left: 0px; width: 240px;" class="file-input-area" name="profileImage" size="30"/>
							<div class="box-layout">
								<div class="inp-center">
									<input class="clear" type="text" value="kuni 1024x1024 px, 1 MB" />
								</div>
							</div>
							<div class="btn-browse">Browse...</div>
						</div>
					</div>
					<!--info-row end-||-info-row start-->
					<div class="info-row veebileht">
						<div class="title">
							<h5>@Resources.EnetaMvc.HomePage</h5>
						</div>
						<div class="information-main">
							<div class="veebileht-row"><!-- example value: http:// -->
								@Html.TextBoxFor(m => m.HomePage, new Dictionary<string,object> { {"class","text-go"} })
								<a class="testi" href="#">testi</a> <a href="inc/help2.html?width=216" id="help6" name="Veebileht" class="jTip">?</a> 
                            </div>
						</div>
					</div>
					<!--info-row end-||-info-row start-->
					<div class="info-row">
						<div class="title">
							<h5>@Resources.EnetaMvc.Address</h5>
						</div>
						<div class="information-main"><!-- example value: Tänav 123, 12345 Asula, Maakond -->
							@Html.TextBoxFor(m => m.Address, new Dictionary<string,object> { {"class","text-go clear"} })
							@Html.CheckBoxFor(m => m.ShowAddress, new Dictionary<string, object> { { "class", "choice" } })
							@Html.LabelFor(m => m.ShowAddress, Resources.EnetaMvc.Public.ToLower())
							<a href="inc/help2.html?width=216" id="help7" name="Postiaadress" class="jTip">?</a> </div>
					</div>
					<!--info-row end-||-info-row start-->
					<div class="info-row">
						<div class="title">
							<h5>@Resources.EnetaMvc.Phone</h5>
						</div>
						<div class="information-main"><!-- example value: 123 456789 -->
							@Html.TextBoxFor(m => m.Phone, new Dictionary<string,object> { {"class","small clear"} })
							@Html.CheckBoxFor(m => m.ShowPhone, new Dictionary<string, object> { { "class", "choice" } })
							@Html.LabelFor(m => m.ShowPhone, Resources.EnetaMvc.Public.ToLower())
						</div>
					</div>
					<!--info-row end-->
				</div>
				<!--input-holder end-||-input-holder start-->
				<div class="input-holder" id="enter-education">
					<!--info-row start-->
					<div class="info-row">
						<div class="title">
							<h5>@Resources.EnetaMvc.School</h5>
						</div>
						<div class="information-main">
                            @Html.TextBoxFor(m => m.School, new Dictionary<string,object> { {"class","text-go"} })
							@Html.CheckBoxFor(m => m.ShowSchool, new Dictionary<string, object> { { "class", "choice" } })
							@Html.LabelFor(m => m.ShowSchool, Resources.EnetaMvc.Public.ToLower())
							<a tabindex="24" class="jTip" name="Help" id="help8" href="inc/help2.html?width=216"> ?</a>
						</div>
					</div>
					<!--info-row end-||-info-row start-->
					<div class="info-row">
						<div class="title">
							<h5>@Resources.EnetaMvc.FieldOfStudy</h5>
						</div>
						<div class="information-main">
                            @Html.TextBoxFor(m => m.FieldOfStudy, new Dictionary<string,object> { {"class","small"} })
							@Html.CheckBoxFor(m => m.ShowFieldOfStudy, new Dictionary<string, object> { { "class", "choice" } })
							@Html.LabelFor(m => m.ShowFieldOfStudy, Resources.EnetaMvc.Public.ToLower())
							<a tabindex="27" class="jTip" name="Help" id="help9" href="inc/help2.html?width=216"> ?</a>
						</div>
					</div>
					<!--info-row end-->
				</div>
				<!--input-holder end-||-input-holder start-->
				<div class="input-holder">
					<!--info-row start-->
					<div class="info-row">
						<div class="title">
							<h5>@Resources.EnetaMvc.Company</h5>
						</div>
						<div class="information-main">
                            @Html.TextBoxFor(m => m.Company, new Dictionary<string,object> { {"class","small"} })
							@Html.CheckBoxFor(m => m.ShowCompany, new Dictionary<string, object> { { "class", "choice" } })
							@Html.LabelFor(m => m.ShowCompany, Resources.EnetaMvc.Public.ToLower())
						</div>
					</div>
					<!--info-row end-||-info-row start-->
					<div class="info-row">
						<div class="title">
							<h5>@Resources.EnetaMvc.JobTitle</h5>
						</div>
						<div class="information-main">
                            @Html.TextBoxFor(m => m.JobTitle, new Dictionary<string,object> { {"class","small"} })
							@Html.CheckBoxFor(m => m.ShowJobTitle, new Dictionary<string, object> { { "class", "choice" } })
							@Html.LabelFor(m => m.JobTitle, Resources.EnetaMvc.Public.ToLower())
						</div>
					</div>
					<!--info-row end-->
				</div>
				<!--input-holder end-->
				<div class="info-footer-section">
					@Html.CheckBoxFor(m => m.SendEventsEmails, new Dictionary<string, object> { { "class", "choice" } })
                    @Html.LabelFor(m => m.SendEventsEmails, Resources.EnetaMvc.SendInfoAboutEvents)
					<a href="inc/help2.html?width=216" id="help10" name="Uudiskiri" class="jTip">?</a> </div>
				<div class="info-footer-section">
					@Html.CheckBoxFor(m => m.SendCommunityEmails, new Dictionary<string, object> { { "class", "choice" } })
                    @Html.LabelFor(m => m.SendCommunityEmails, Resources.EnetaMvc.SendMsInfo)
					<a href="inc/help2.html?width=216" id="help11" name="Uudiskiri" class="jTip">?</a> </div>
				<div class="submit">
					<input type="submit" value="@Resources.EnetaMvc.Save"/>
				</div>
				<a class="loobu" href="@Url.Content("~/")">@Resources.EnetaMvc.Cancel</a>
				</fieldset>
			@{ Html.EndForm(); }
			@Html.GetHtmlAreaByName("ProfileEdit")
		</div>
	</div>
</div>